﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;
using XStudio.XCRF.Resources.Items;

namespace XStudio.XCRF.Web.Models.Items
{
    public class DukesInfo
    {
        private static IEnumerable<SelectListItem> _SelectListItems;
        public static IEnumerable<SelectListItem> SelectListItems
        {
            get
            {
                if (_SelectListItems == null)
                {
                    List<SelectListItem> items = new List<SelectListItem>();
                    items.Add(new SelectListItem { Text = DukesResource.NULL, Value = string.Empty });
                    string[] keys = { "A1", "A2", "A3", "B", "C", "D" };
                    string[] DukesAdvice = {"局限于黏膜及黏膜下层", "侵入浅肌层", 
                                            "侵入深肌层","癌穿透浆膜",
                                            "有局部淋巴结转移","有远处转移" 
                                           };
                    int i = -1;
                    foreach (string key in keys)
                        items.Add(new SelectListItem
                        {
                            Text = DukesResource.ResourceManager.GetString(key)+"（"+DukesAdvice[++i]+"）",
                            Value = key
                        });
                    _SelectListItems = items;
                }
                return _SelectListItems;
            }
        }
    }
}